import request from '@/utils/request'

export function getShopList (params:any) {
    return request({
        url: 'store.shop/list',
        method: 'GET',
        params
    })
}

export function getShopSelect () {
    return request({
        url: 'store.shop/select',
        method: 'GET'
    })
}

export function createShop (data:any) {
    return request({
        url: 'store.shop/create',
        method: 'POST',
        data
    })
}
export function updateShop (data:any) {
    return request({
        url: `store.shop/update`,
        method: 'PUT',
        data
    })
}
export function updateStatusShop (data:{id:number|string,status:number|string}) {
    return request({
        url: `store.shop/status`,
        method: 'PUT',
        data
    })
}
export function delShop (data:{id:number|string}) {
    return request({
        url: `store.shop/delete`,
        method: 'DELETE',
        data
    })
}

export function getShopDetail (params:{id:number|string}) {
    return request({
        url: `store.shop/detail`,
        method: 'GET',
        params
    })
}
